//
//  ViewController.m
//  16-UICollectionViewCycleImage
//
//  Created by 李昊林 on 16/8/4.
//  Copyright © 2016年 李昊林. All rights reserved.
//

#import "ViewController.h"
#import "LHLCycleImages.h"
@interface ViewController ()
@property (weak, nonatomic) IBOutlet LHLCycleImages *cycleImage;
@property (nonatomic, strong) NSTimer *timer;
@end

@implementation ViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    
    
    // Do any additional setup after loading the view, typically from a nib.
    //    PFCycleImages *cycle = [[PFCycleImages alloc] initWithFrame:CGRectMake(0, 0, self.view.frame.size.width, 200)];
    //    [self.view addSubview:cycle];
    NSMutableArray *strArray = [NSMutableArray array];
    NSMutableArray *array = [NSMutableArray array];
    for (int i = 0; i < 5; i++) {
        [array addObject:[NSString stringWithFormat:@"%d.jpg", i]];
        [strArray addObject:[NSString stringWithFormat:@"第%d张图片", i]];
    }
    
    NSString *firstImage = [array firstObject];
    NSString *lastImage = [array lastObject];
    [array insertObject:lastImage atIndex:0];
    [array addObject:firstImage];
    _cycleImage.array = array;
    _cycleImage.titleArray = strArray;
}

//- (void)handleDataWithObject:(NSString * )objc cell:(LHLImageCell *)cell {
//    ceil.cycleImage.image = [UIImage imageNamed:objc]
//}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

@end

